package com.jdrx.ocp.beans.event;

import com.jdrx.ocp.beans.constans.EventActionEnum;
import com.jdrx.ocp.beans.constans.EventEnum;
import org.springframework.context.ApplicationEvent;

/**
 * 应用服务通知事件处理
 * @Author: Huangxg
 * @Date: 2019/1/17 16:58
 */
public class NoticesEvent extends ApplicationEvent {

    private EventEnum eventEnum;
    private EventActionEnum eventActionEnum;
    private String data;

    public NoticesEvent(Object source, EventEnum eventEnum, EventActionEnum eventActionEnum,String data) {
        super(source);
        this.eventEnum = eventEnum;
        this.eventActionEnum = eventActionEnum;
        this.data = data;
    }

    public NoticesEvent(Object source, EventEnum eventEnum, EventActionEnum eventActionEnum) {
        super(source);
        this.eventEnum = eventEnum;
        this.eventActionEnum = eventActionEnum;
        this.data = null;
    }

    public EventEnum getEventEnum() {
        return eventEnum;
    }

    public void setEventEnum(EventEnum eventEnum) {
        this.eventEnum = eventEnum;
    }

    public EventActionEnum getEventActionEnum() {
        return eventActionEnum;
    }

    public void setEventActionEnum(EventActionEnum eventActionEnum) {
        this.eventActionEnum = eventActionEnum;
    }

    public String getData() {
        return data;
    }

    public void setData(String data) {
        this.data = data;
    }
}
